/**
 * Created by John on 2016/6/20.
 */

var config = {
    verbose: true,
    port: 27017,
    dbpath: '/data/db',
    noauth: true
};

db.addUser({
    user: 'testUser',
    userSource: 'test',
    roles: ['read'],
    otherDBRoles: {testDB2: ['readWrite']}
});

db.system.users.find();

printjson(db.getCollectionNames());

load('/data/db/get_collections.js');

db = connect('localhost/words');
printjson(db.getCollectionNames());



